package com.yubest.demo2.feign;

import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * @Author hweiyu
 * @Description
 * @Date 2021/7/14 17:20
 */
@FeignClient(name = "feign-service")
public interface HelloService {

    /**
     * 注：GET请求时，org.springframework.web.bind.annotation.RequestParam是必需的，否则会报错
     * @param msg
     * @return
     */
    @GetMapping(value = "/hello")
    String hello(@RequestParam("msg") String msg);
}
